﻿using System;
using System.ServiceProcess;

namespace HostsUpdaterCore {
    static class Program {
        private static string _path = AppDomain.CurrentDomain.BaseDirectory;

        static void Main() {
            Release();
        }

        static void Release() {
            ServiceBase[] ServicesToRun;
            ServicesToRun = new ServiceBase[] 
                { 
                    new HostsUpdaterService()
                };
            ServiceBase.Run(ServicesToRun);
        }

        static void Debug() {
            Just_Ping just_Ping = new Just_Ping("google.com");
            just_Ping.Query();
            just_Ping.GenerateHostsFile(_path);
        }
    }
}
